import logging

def logger():
    log = logging.basicConfig(level=logging.DEBUG,
                              filename='a.log',
                              filemode='a+',
                              format='%(thread)d %(funcName)s %(asctime)s %(message)s')
    return log